import {BasicColumn} from '/@/components/Table';
import {FormSchema} from '/@/components/Table';
import { rules} from '/@/utils/helper/validator';
import { render } from '/@/utils/common/renderUtils';
//列表数据
export const columns: BasicColumn[] = [
  {
    title: '平台机构编码',
    align: "center",
    dataIndex: 'sysOrg'
  },
  {
    title: '机构名称',
    align: "center",
    dataIndex: 'name'
  },
  {
    title: 'SecretId',
    align: "center",
    dataIndex: 'secretId'
  },
  {
    title: 'SecretKey',
    align: "center",
    dataIndex: 'secretKey'
  },
  {
    title: 'sdkAppId',
    align: "center",
    dataIndex: 'sdkAppid'
  },
  {
    title: 'signName',
    align: "center",
    dataIndex: 'signName'
  },
  {
    title: 'templateId',
    align: "center",
    dataIndex: 'templateId'
  },
  {
    title: '是否有效',
    align: "center",
    dataIndex: 'isValidate'
  },
];

//查询数据
export const searchFormSchema: FormSchema[] = [
];

//表单数据
export const formSchema: FormSchema[] = [
  {
    label: '平台机构编码',
    field: 'sysOrg',
    component: 'Input',
  },
  {
    label: '机构名称',
    field: 'name',
    component: 'Input',
  },
  {
    label: 'SecretId',
    field: 'secretId',
    component: 'Input',
  },
  {
    label: 'SecretKey',
    field: 'secretKey',
    component: 'Input',
  },
  {
    label: 'sdkAppId',
    field: 'sdkAppid',
    component: 'Input',
  },
  {
    label: 'signName',
    field: 'signName',
    component: 'Input',
  },
  {
    label: 'templateId',
    field: 'templateId',
    component: 'Input',
  },
  {
    label: '是否有效',
    field: 'isValidate',
    component: 'Input',
  },
	// TODO 主键隐藏字段，目前写死为ID
  {
    label: '',
    field: 'id',
    component: 'Input',
    show: false,
  },
];

// 高级查询数据
export const superQuerySchema = {
  sysOrg: {title: '平台机构编码',order: 0,view: 'text', type: 'string',},
  name: {title: '机构名称',order: 1,view: 'text', type: 'string',},
  secretId: {title: 'SecretId',order: 2,view: 'text', type: 'string',},
  secretKey: {title: 'SecretKey',order: 3,view: 'text', type: 'string',},
  sdkAppid: {title: 'sdkAppId',order: 4,view: 'text', type: 'string',},
  signName: {title: 'signName',order: 5,view: 'text', type: 'string',},
  templateId: {title: 'templateId',order: 6,view: 'text', type: 'string',},
  isValidate: {title: '是否有效',order: 7,view: 'text', type: 'string',},
};
